The present invention relates to transmission codes and, more particularly, relates to methods and apparatuses used to produce and interpret Direct Current (DC) balanced 7B/8B, 9B/10B, and partitioned DC balanced 12B/14B, 17B/20B, and 16B/18B transmission codes.
One purpose of transmission codes is to transform the frequency spectrum of a serial data stream so that clocking can be recovered readily and AC (alternating current) coupling is possible. A transmission code must also provide special characters outside the data alphabet for functions such as character synchronization, frame delimiters and perhaps for abort, reset, idle, diagnostics, and other functions. Codes are also used, often in combination with signal waveform shaping, to adapt the signal spectrum more closely to specific channel requirements. In most cases, a reduction in bandwidth by constraints on both the high and the low frequency components is desirable to reduce distortion in the transmission media, especially electromagnetic cables, or in a band limited receiver, and to reduce the effects of extrinsic and intrinsic noise.
For fiber optic links and intra-establishment wire links, interest centers for many reasons on a family of two-level codes. For wire links, one prefers codes with no DC (direct current) and little low frequency content in order to DC-isolate the transmission line from the driver and receiver circuitry, by transformers or capacitors, and to reduce signal distortion on the line. Although these factors do not apply to the fiber optic case, good low frequency characteristics of the code are still helpful for a number of reasons.
For instance, high gain fiber optic receivers need an AC coupling stage near the front end. The control of the drive level, receiver gain, and equalization is simplified and the precision of control is improved, if it can be based on the average signal power, especially at top data rates. DC restore circuits tend to lose precision with rising data rates and cease to operate properly below the maximum rates for other circuits required in a transceiver. Finally, if the time constants associated with the parasitic capacitances at the front end of a receiver are comparable to or longer than a baud interval, a signal with reduced low frequency content will suffer less distortion and will enable many links to operate without an equalizing circuit.
Manchester and related codes are simple two-level codes and solve the clocking and low frequency problems very well. These codes translate each bit into two bits for transmission and are a good choice whenever the high clocking rates cause no problems in the logic or analog circuits, in the transducers, or on the transmission line. They also reduce the data transmission rate by a factor of two since they encode 2 bits for every data bit (i.e., these codes are called rate xc2xd codes).
There are additional codes that solve or ameliorate the clocking and low frequency problems yet also provide higher data transmission rates. For instance, simple 5B/6B codes translate five binary bits into six binary digits and raise the number of information bits transmitted per baud interval to 0.833. There are also 7B/8B and 9B/10B codes that additionally raise the data transmission rate.
However, there is still a need to provide suitable transmission codes that provide reduced complexity during encoding and decoding and yet provide enough flexibility to be able to be modified for other applications.
The present invention provides techniques for classifying disparities and source vectors for 7B/8B and 9B/10B transmission codes, which are then used to minimize the complexity of decoding and encoding for 16B/18B codes. Furthermore, decoding for 7B/8B, 9B/10B, and 16B/18B transmission codes is simplified through techniques discussed below. Additionally, the present invention provides techniques for encoding and decoding 12B/14B and 17B/20B transmission codes using the classifications and decoding techniques for the 5B,6B, 7B/8B and 9B/10B transmission codes.
In a first aspect of the invention, the encoding space for 7B/8B and 9B/10B codes is divided into classifications. The classifications are preferably determined for source vectors, which are uncoded vectors, and for disparity for coded vectors. The disparity is the difference between the number of one and zero bits in a defined block of bits, which in this case is the coded vector. As described in more detail below, disparity is important in maintaining a DC balanced code. In one embodiment, the vector classifications are selected in a predetermined manner so that the number of classifications is minimized for bit mapping, disparity control, or both. Bit mapping is basically the conversion of source vectors to coded vectors. Disparity control is basically how the disparity is maintained per 7B/8B, 9B/10B, or 16B/18B vector. In another embodiment, the number of bits changed for bit mapping is minimized. Benefits to classification as per the above techniques are reduced encoder and decoder complexity and additional flexibility within the 7B/8B and 9B/10B transmission codes to allow the codes to be more easily converted for use with transmission codes other than the 16B/18B transmission code.
In a second aspect of the invention, decoding of 7B/8B and 9B/10B transmission codes is performed by converting coded vectors into a single image and then performing decoding operations to decode the coded vectors. This aspect has a benefit of reduced decoding complexity, as only the single image need be decoded. In one embodiment, the single image is a primary coded vector, and an alternate coded vector is an inverted version of the primary coded vector. When a coded vector is to be decoded, it is determined whether the coded vector is a primary or alternate coded vector. If the coded vector is a primary coded vector, then the coded vector is simply decoded. If the coded vector is an alternate coded vector, then the coded vector is inverted and then decoded. In a second embodiment, a single bit is used to determine if the coded vector is a primary or alternate coded vector. In a third embodiment, the single bit and the classification of the encoded vector are used to determine if the coded vector is a primary or alternate coded vector. Additionally, in this aspect, the classifications are preferably designed to support this single image decoding technique.
In a third aspect of the invention, techniques are presented for using the B/6B, 7B/8B, and 9B/10B transmission codes in other transmission codes such as 12B/14B and 17B/20B transmission codes. For instance, a 17B/20B transmission code ay be created by using two parallel 9B/10B decoders or by using one 7B/8B encoder and two 5B/6B encoders.